package com.ruoyi.system.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 系统用户对象 user
 * 
 * @author ruoyi
 * @date 2025-01-09
 */
public class User extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键ID */
    private Long id;

    /** 账号 */
    @Excel(name = "账号")
    private String account;

    /** 真实姓名 */
    @Excel(name = "真实姓名")
    private String realName;

    /** 密码 */
    @Excel(name = "密码")
    private String password;

    /** 性别（1:女、 2:男） */
    @Excel(name = "性别", readConverterExp = "1=:女、,2=:男")
    private Long sex;

    /** 出生日期（年-月-日） */
    @Excel(name = "出生日期", readConverterExp = "年=-月-日")
    private Date birthday;

    /** 手机号码 */
    @Excel(name = "手机号码")
    private String phone;

    /** 用户地址 */
    @Excel(name = "用户地址")
    private String address;

    /** 用户角色id */
    @Excel(name = "用户角色id")
    private Long roleId;

    /** 创建人 */
    @Excel(name = "创建人")
    private Long createdUserId;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createdTime;

    /** 修改人 */
    @Excel(name = "修改人")
    private Long updatedUserId;

    /** 修改时间 */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date updatedTime;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }

    public void setAccount(String account) 
    {
        this.account = account;
    }

    public String getAccount() 
    {
        return account;
    }

    public void setRealName(String realName) 
    {
        this.realName = realName;
    }

    public String getRealName() 
    {
        return realName;
    }

    public void setPassword(String password) 
    {
        this.password = password;
    }

    public String getPassword() 
    {
        return password;
    }

    public void setSex(Long sex) 
    {
        this.sex = sex;
    }

    public Long getSex() 
    {
        return sex;
    }

    public void setBirthday(Date birthday) 
    {
        this.birthday = birthday;
    }

    public Date getBirthday() 
    {
        return birthday;
    }

    public void setPhone(String phone) 
    {
        this.phone = phone;
    }

    public String getPhone() 
    {
        return phone;
    }

    public void setAddress(String address) 
    {
        this.address = address;
    }

    public String getAddress() 
    {
        return address;
    }

    public void setRoleId(Long roleId) 
    {
        this.roleId = roleId;
    }

    public Long getRoleId() 
    {
        return roleId;
    }

    public void setCreatedUserId(Long createdUserId) 
    {
        this.createdUserId = createdUserId;
    }

    public Long getCreatedUserId() 
    {
        return createdUserId;
    }

    public void setCreatedTime(Date createdTime) 
    {
        this.createdTime = createdTime;
    }

    public Date getCreatedTime() 
    {
        return createdTime;
    }

    public void setUpdatedUserId(Long updatedUserId) 
    {
        this.updatedUserId = updatedUserId;
    }

    public Long getUpdatedUserId() 
    {
        return updatedUserId;
    }

    public void setUpdatedTime(Date updatedTime) 
    {
        this.updatedTime = updatedTime;
    }

    public Date getUpdatedTime() 
    {
        return updatedTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("account", getAccount())
            .append("realName", getRealName())
            .append("password", getPassword())
            .append("sex", getSex())
            .append("birthday", getBirthday())
            .append("phone", getPhone())
            .append("address", getAddress())
            .append("roleId", getRoleId())
            .append("createdUserId", getCreatedUserId())
            .append("createdTime", getCreatedTime())
            .append("updatedUserId", getUpdatedUserId())
            .append("updatedTime", getUpdatedTime())
            .toString();
    }
}
